package com.example.samples;

import android.app.Activity;
import android.graphics.drawable.AnimationDrawable;
import android.os.Bundle;
import android.view.View;
import android.view.animation.Animation;
import com.example.R;

/**
 * Created with IntelliJ IDEA.
 * User: Andrei
 * Date: 7/29/12
 * Time: 9:37 PM
 * To change this template use File | Settings | File Templates.
 */
public class ExampleFrame extends Activity {
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.example_frame);
        findViewById(R.id.iv).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                AnimationDrawable a = (AnimationDrawable) findViewById(R.id.iv).getBackground();
                a.start();
            }
        });
    }

}